package il.ac.tau.cg.ex3.entities.scene.lights;

import il.ac.tau.cg.ex3.entities.styles.Color;
import il.ac.tau.cg.ex3.math.Point;
import il.ac.tau.cg.ex3.math.Vector;

public class DirectionalLight extends Light
{
	private Vector direction;
	
	public DirectionalLight(Color color, Vector direction)
	{
		super(color);
		
		this.direction = direction;
	}

	@Override
	public Color getIntensity(Point point)
	{
		return getColor();
	}
	
	@Override
	public Vector getDirection(Point point)
	{
		return getDirection().normalize();
	}
	
	public Vector getDirection()
	{
		return direction;
	}

	public void setDirection(Vector direction)
	{
		this.direction = direction;
	}
}
